package com.zenchn.dao;

import com.zenchn.generic.GenericDao;
import com.zenchn.model.TSysAuthority;
import com.zenchn.model.TSysRoleAuthorityMapper;
import com.zenchn.model.TSysRoleAuthorityMapperExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface TSysRoleAuthorityMapperMapper extends GenericDao<TSysRoleAuthorityMapper, String, TSysRoleAuthorityMapperExample> {

    @Override
    long countByExample(TSysRoleAuthorityMapperExample example);

    @Override
    int deleteByExample(TSysRoleAuthorityMapperExample example);

    @Override
    int insert(TSysRoleAuthorityMapper record);

    @Override
    int insertSelective(TSysRoleAuthorityMapper record);

    @Override
    List<TSysRoleAuthorityMapper> selectByExample(TSysRoleAuthorityMapperExample example);

    @Override
    int updateByExampleSelective(@Param("record") TSysRoleAuthorityMapper record, @Param("example") TSysRoleAuthorityMapperExample example);

    @Override
    int updateByExample(@Param("record") TSysRoleAuthorityMapper record, @Param("example") TSysRoleAuthorityMapperExample example);

    /**
     * 通过角色id 列表  查询角色 拥有的权限
     *
     * @param roleId
     * @return
     */
    List<TSysAuthority> selectAuthorityByRoleId(String roleId);
}